package net.lahuobao.mall.entity.admin;

import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.*;

import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.GenericGenerator;

/**   
 * @Title: Entity
 * @Description: ETC卡申请管理
 * @author zhangdaihao
 * @date 2016-12-02 16:48:01
 * @version V1.0   
 *
 */
@Entity
@Table(name = "mall_etc_apply", schema = "lahuobao")
@DynamicUpdate(true)
@DynamicInsert(true)
@SuppressWarnings("serial")
public class MallEtcApplyEntity implements java.io.Serializable {
	/**id*/
	private java.lang.Integer id;
	/**申请人*/
	private java.lang.Integer applyuserid;
	/**申请单号*/
	private java.lang.String applyno;
	/**车牌号*/
	private java.lang.String carno;
	/**店铺*/
	private java.lang.Integer shopid;
	/**行驶证*/
	private java.lang.String vehiclelicenseimg;
	/*身份证正面*/
	private java.lang.String idCardNoHeadsImg;
	/*身份证反面*/
	private java.lang.String idCardNoTailsImg;
	/*车辆照片**/
	private java.lang.String vehicleimg;
	/**申请时间*/
	private java.util.Date applytime;
	/**状态,已申请未支付_0,已支付未受理_1,待发卡_2,待收货_3,已收货_4,商户审核未通过_10,已取消_11*/
	private java.lang.Integer state;
	/**拒绝原因*/
	private java.lang.String refectreason;
	/*用户取消原因*/
	private java.lang.String cancelreason;
	/**ETC卡号*/
	private java.lang.String ectcardno;
	/**领卡方式，0现场领卡，1邮寄*/
	private java.lang.Integer receivetype;
	/**首次领卡订单id*/
	private java.lang.Integer orderid;
	/*邮寄地址*/
	private java.lang.Integer mailingAddressId;
	/*现场领卡地址*/
	private Integer livetakeaddressid;

	private MallShopEntity shop;

	private MallUserEntity mallUser;

	/**
	 *方法: 取得java.lang.Integer
	 *@return: java.lang.Integer  id
	 */
	
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name ="ID",nullable=false,precision=10,scale=0)
	public java.lang.Integer getId(){
		return this.id;
	}

	/**
	 *方法: 设置java.lang.Integer
	 *@param: java.lang.Integer  id
	 */
	public void setId(java.lang.Integer id){
		this.id = id;
	}
	/**
	 *方法: 取得java.lang.Integer
	 *@return: java.lang.Integer  申请人
	 */
	@Column(name ="APPLYUSERID",nullable=false,precision=10,scale=0)
	public java.lang.Integer getApplyuserid(){
		return this.applyuserid;
	}

	/**
	 *方法: 设置java.lang.Integer
	 *@param: java.lang.Integer  申请人
	 */
	public void setApplyuserid(java.lang.Integer applyuserid){
		this.applyuserid = applyuserid;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  申请单号
	 */
	@Column(name ="APPLYNO",nullable=true,length=50)
	public java.lang.String getApplyno(){
		return this.applyno;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  申请单号
	 */
	public void setApplyno(java.lang.String applyno){
		this.applyno = applyno;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  车牌号
	 */
	@Column(name ="CARNO",nullable=false,length=20)
	public java.lang.String getCarno(){
		return this.carno;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  车牌号
	 */
	public void setCarno(java.lang.String carno){
		this.carno = carno;
	}
	/**
	 *方法: 取得java.lang.Integer
	 *@return: java.lang.Integer  店铺
	 */
	@Column(name ="SHOPID",nullable=false,precision=10,scale=0)
	public java.lang.Integer getShopid(){
		return this.shopid;
	}

	/**
	 *方法: 设置java.lang.Integer
	 *@param: java.lang.Integer  店铺
	 */
	public void setShopid(java.lang.Integer shopid){
		this.shopid = shopid;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  行驶证
	 */
	@Column(name ="VEHICLELICENSEIMG",nullable=true,length=200)
	public java.lang.String getVehiclelicenseimg(){
		return this.vehiclelicenseimg;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  行驶证
	 */
	public void setVehiclelicenseimg(java.lang.String vehiclelicenseimg){
		this.vehiclelicenseimg = vehiclelicenseimg;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  drivinglicenseimg
	 */

	@Column(name ="idCardNoHeadsImg",nullable=false,length=200)
	public String getIdCardNoHeadsImg() {
		return idCardNoHeadsImg;
	}

	public void setIdCardNoHeadsImg(String idCardNoHeadsImg) {
		this.idCardNoHeadsImg = idCardNoHeadsImg;
	}

	@Column(name ="idCardNoTailsImg",nullable=false,length=200)
	public String getIdCardNoTailsImg() {
		return idCardNoTailsImg;
	}

	public void setIdCardNoTailsImg(String idCardNoTailsImg) {
		this.idCardNoTailsImg = idCardNoTailsImg;
	}

	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  vehicleimg
	 */
	@Column(name ="VEHICLEIMG",nullable=true,length=200)
	public java.lang.String getVehicleimg(){
		return this.vehicleimg;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  vehicleimg
	 */
	public void setVehicleimg(java.lang.String vehicleimg){
		this.vehicleimg = vehicleimg;
	}
	/**
	 *方法: 取得java.util.Date
	 *@return: java.util.Date  申请时间
	 */
	@Column(name ="APPLYTIME",nullable=false)
	public java.util.Date getApplytime(){
		return this.applytime;
	}

	/**
	 *方法: 设置java.util.Date
	 *@param: java.util.Date  申请时间
	 */
	public void setApplytime(java.util.Date applytime){
		this.applytime = applytime;
	}
	/**
	 *方法: 取得java.lang.Integer
	 *@return: java.lang.Integer  状态,已申请未支付_0,已支付未受理_1,待发卡_2,待收货_3,已收货_4,商户审核未通过_10,已取消_11
	 */
	@Column(name ="STATE",nullable=false,precision=10,scale=0)
	public java.lang.Integer getState(){
		return this.state;
	}

	/**
	 *方法: 设置java.lang.Integer
	 *@param: java.lang.Integer  状态,已申请未支付_0,已支付未受理_1,待发卡_2,待收货_3,已收货_4,商户审核未通过_10,已取消_11
	 */
	public void setState(java.lang.Integer state){
		this.state = state;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  拒绝原因
	 */
	@Column(name ="REFECTREASON",nullable=true,length=200)
	public java.lang.String getRefectreason(){
		return this.refectreason;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  拒绝原因
	 */
	public void setRefectreason(java.lang.String refectreason){
		this.refectreason = refectreason;
	}
	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  ETC卡号
	 */
	@Column(name ="ECTCARDNO",nullable=true,length=10)
	public java.lang.String getEctcardno(){
		return this.ectcardno;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  ETC卡号
	 */
	public void setEctcardno(java.lang.String ectcardno){
		this.ectcardno = ectcardno;
	}

	/**
	 * 领卡方式
	 * @return
	 */
	@Column(name ="RECEIVETYPE",nullable=true,length=10)
	public Integer getReceivetype() {
		return receivetype;
	}

	public void setReceivetype(Integer receivetype) {
		this.receivetype = receivetype;
	}

	/**
	 *方法: 取得java.lang.String
	 *@return: java.lang.String  首次领卡订单id
	 */
	@Column(name ="ORDERID",nullable=true,length=10)
	public java.lang.Integer getOrderid(){
		return this.orderid;
	}

	/**
	 *方法: 设置java.lang.String
	 *@param: java.lang.String  首次领卡订单id
	 */
	public void setOrderid(java.lang.Integer orderid){
		this.orderid = orderid;
	}

	@OneToOne
	@JoinColumn(name = "shopid", insertable = false, updatable = false)
	public MallShopEntity getShop() {
		return shop;
	}

	public void setShop(MallShopEntity shop) {
		this.shop = shop;
	}

	@OneToOne
	@JoinColumn(name = "applyuserid", insertable = false, updatable = false)
	public MallUserEntity getMallUser() {
		return mallUser;
	}

	public void setMallUser(MallUserEntity mallUser) {
		this.mallUser = mallUser;
	}

	@Column(name ="mailingAddressId",nullable=false,precision=10,scale=0)
	public Integer getMailingAddressId() {
		return mailingAddressId;
	}

	public void setMailingAddressId(Integer mailingAddressId) {
		this.mailingAddressId = mailingAddressId;
	}

	@Column(name ="cancelReason",nullable=false,length=10)
	public String getCancelreason() {
		return cancelreason;
	}

	public void setCancelreason(String cancelreason) {
		this.cancelreason = cancelreason;
	}

	@Column(name ="livetakeaddressid",nullable=false,precision=10,scale=0)
	public Integer getLivetakeaddressid() {
		return livetakeaddressid;
	}

	public void setLivetakeaddressid(Integer livetakeaddressid) {
		this.livetakeaddressid = livetakeaddressid;
	}
}
